package com.edu.robot.core.enums;

import lombok.Getter;

@Getter
public enum NotifyMsgEnum {

	//生成题目消息
	TITLE("title","生成题目"),

	//普通消息
	NORMAL("normal","普通消息"),

	//检索知识库消息
	KNOWLEDGE("knowledge","知识库消息"),

	//检索工具消息
	TOOL("tool","工具消息");

	private final String code;

	private final String desc;

	NotifyMsgEnum(String code,String desc){
		this.code = code;
		this.desc = desc;
	}

	public static NotifyMsgEnum getNotifyMsgByCode(String code) {
		for (NotifyMsgEnum notifyMsgEnum : NotifyMsgEnum.values()) {
			if (notifyMsgEnum.getCode().equals(code)) {
				return notifyMsgEnum;
			}
		}
		return null;
	}


}
